package com.imooc.ad.dao;

import com.imooc.ad.entity.AdUnit;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

/**
 * @author Qihs
 *
 * 关联的实体类定义<AdUnit, Long>
 */
public interface AdUnitRepository extends JpaRepository<AdUnit, Long>{

    AdUnit findByPlanIdAndUnitName(Long planId, String unitName);


    List<AdUnit> findAllByUnitStatus(Integer unitStatus);
}
